package edu.mit.compilers.lowercode.code;

/*
 * like empty code ,the label is the method name
 */
public class MethodBeginCode extends ThreeAddressCode {

    private final String methodName;
    @Override
    protected String getStringFroShow(String prefix) {
        return prefix;
    }

    @Override
    public <T> T accept(ThreadAddressCodeVistor<T> visitor) {
        return visitor.visit(this);
    }

    public MethodBeginCode(String methodName) {
        this.methodName = methodName;
    }

    public String getMethodName() {
        return methodName;
    }
}
